<admintpl file="header" />
</head>
<body>
<div class="wrap js-check-wrap">
	<ul class="nav nav-tabs">
		<li class="active"><a href="{:U('Chat/AdminIndex/index',array('cid'=>$cid))}">聊天列表</a></li>
	</ul>

	<form class="well form-search" method="post" action="{:U('AdminIndex/index')}">
		<input type="text" name="content" style="width: 300px;" value="{:I('request.content/s')}" placeholder="请输入聊天关键字"/>

		<input type="text" name="start_time" class="js-datetime" value="{$formget.start_time|default=''}" style="width: 120px;" autocomplete="off"  placeholder="聊天结束时间" >-
		<input type="text" name="end_time" class="js-datetime" value="{$formget.end_time|default=''}" style="width: 120px;" autocomplete="off"  placeholder="聊天结束时间" > &nbsp; &nbsp;


		<input type="submit" class="btn btn-primary" value="搜索" />
		<a class="btn btn-danger" href="{:U('AdminIndex/index')}">清空</a>
	</form>


	<form class="js-ajax-form" method="post">
		<div class="table-actions">
			<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Chat/AdminPikaIndex/indexBat','type=delete')}">删除</button>
		</div>
		<table class="table table-hover table-bordered table-list">
			<thead>
			<tr>
				<th width="16"><label><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x"></label></th>
				<th width="50">ID</th>
				<th width="60">消息ID</th>
				<th>聊天发起者</th>
				<th>聊天接收者</th>
				<th>聊天的内容</th>
				<th>聊天的时间</th>
				<th>操作</th>
			</tr>
			</thead>
			<foreach name="lists" item="v">
				<tr>
					<td style="vertical-align:middle;"><input type="checkbox" class="js-check" data-yid="js-check-y" data-xid="js-check-x" name="ids[]" value="{$v['message_id']}" title="ID:{$v['message_id']}"></td>
					<td>{$v.message_id}</td>
					<td>{$v.client_msg_id}</td>
					<td>{$v.from_mobile}-<if condition="empty($v['from_nicename'])">未设置昵称<else />{$v.from_nicename}</if></td>
					<td>{$v.to_mobile}-<if condition="empty($v['to_nicename'])">未设置昵称<else />{$v.to_nicename}</if></td>
					<td>{$v.content}</td>
					<td>{$v.create_time|date='Y-m-d H:i:s',###}</td>
					<td>
						<a href="{:U('Chat/AdminIndex/delete','message_id='.$v['message_id'])}" class="js-ajax-delete">删除</a>
					</td>
				</tr>
			</foreach>
			<tfoot>
			<tr>
				<th width="16"><label><input type="checkbox" class="js-check-all" data-direction="x" data-checklist="js-check-x"></label></th>
				<th width="50">ID</th>
				<th width="60">消息ID</th>
				<th>聊天发起者</th>
				<th>聊天接收者</th>
				<th>聊天的内容</th>
				<th>聊天的时间</th>
				<th>操作</th>
			</tr>
			</tfoot>
		</table>
		<div class="table-actions">
			<button class="btn btn-primary btn-small js-ajax-submit" type="submit" data-action="{:U('Chat/AdminPikaIndex/indexBat','type=delete')}">删除</button>
		</div>
	</form>

	<div class="pagination"> <ul>{$page}</ul></div>



</div>
<script src="__PUBLIC__/js/common.js"></script>
</body>
</html>